package com.yuw.oop.extendsdemo;

public class Person {
	// 属性
	private String perName; // 私有的
	String perSex; // 默认的
	protected int perAge; // 保护的
	public String perAddress; // 公有的

	// 行为
	public void doSleeping() {
		System.out.println(perName + " is sleeping...");
	}

	public void doEating() {
		System.out.println(perName + " is eating... ");
	}

	// getter/setter接口
	public String getPerName() {
		return perName;
	}

	public void setPerName(String perName) {
		this.perName = perName;
	}

	public String getPerSex() {
		return perSex;
	}

	public void setPerSex(String perSex) {
		this.perSex = perSex;
	}

	public int getPerAge() {
		return perAge;
	}

	public void setPerAge(int perAge) {
		this.perAge = perAge;
	}

	public String getPerAddress() {
		return perAddress;
	}

	public void setPerAddress(String perAddress) {
		this.perAddress = perAddress;
	}

}
